home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-desktop-9.10-i386-PL.iso / casper / filesystem.squashfs / etc / bash_completion.d / qdbus < prev    next >
Text File  |  2009-04-02  |  453b  |  21 lines

  1. # -*- mode: shell-script; sh-basic-offset: 8; indent-tabs-mode: t -*-
  2. # ex: ts=8 sw=8 noet filetype=sh
  3. #
  4. # Qt qdbus completion
  5. #
  6. have qdbus &&
  7. _qdbus()
  8. {
  9.     local cur compstr
  10.     
  11.     COMPREPLY=()
  12.     cur=`_get_cword`
  13.     if [ -z "$cur" ]; then
  14.         compstr=${COMP_WORDS[*]}
  15.     else
  16.         compstr=$( command echo ${COMP_WORDS[*]} | sed "s/ ${cur/\//\\/}$//" )
  17.     fi
  18.     COMPREPLY=( $( compgen -W '$( command $compstr | sed s/\(.*\)// )' -- "$cur" ) )
  19. } &&
  20. complete -F _qdbus qdbus
  21.